package com.company.beauty.common.config.properties;

import lombok.Data;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.cloud.context.config.annotation.RefreshScope;
import org.springframework.stereotype.Component;

import java.io.Serializable;

/**
 * <p>缓存配置</p>
 *
 * @author youyoukele
 * @version 1.0
 * @date 2023/8/4 14:35
 */
@ConfigurationProperties(prefix = "cache")
@Component
@Data
@RefreshScope
public class CacheProperties implements Serializable {
    private static final long serialVersionUID = 4250875291554472034L;
    /**
     * 默认-过期时间(30天)
     */
    private Integer defaultExpireDays = 30;

    /**
     * 最大-过期时间(365天)
     */
    private Integer maxExpireDays = 365;

    /**
     * 最小-过期时间(7天)
     */
    private Integer minExpireDays = 7;

}
